
package org.springxrsk.modules.classes.wrapper;

import org.springxrsk.core.mp.support.BaseEntityWrapper;
import org.springxrsk.core.tool.utils.BeanUtil;
import org.springxrsk.modules.classes.pojo.entity.QyTaskEntity;
import org.springxrsk.modules.classes.pojo.vo.QyTaskVO;
import java.util.Objects;

/**
 * 作业管理 包装类,返回视图层所需的字段
 *
 *  @author
 * @since 2024-06-15
 */
public class QyTaskWrapper extends BaseEntityWrapper<QyTaskEntity, QyTaskVO>  {

	public static QyTaskWrapper build() {
		return new QyTaskWrapper();
 	}

	@Override
	public QyTaskVO entityVO(QyTaskEntity qyTask) {
		QyTaskVO qyTaskVO = Objects.requireNonNull(BeanUtil.copyProperties(qyTask, QyTaskVO.class));

		//User createUser = UserCache.getUser(qyTask.getCreateUser());
		//User updateUser = UserCache.getUser(qyTask.getUpdateUser());
		//qyTaskVO.setCreateUserName(createUser.getName());
		//qyTaskVO.setUpdateUserName(updateUser.getName());

		return qyTaskVO;
	}


}
